#ifndef _HISTOGRAM_H_
#define _HISTOGRAM_H_

#include <string.h>
#include <stdlib.h>

typedef struct histogram{
	int total_key_num;
	int width;
	int size;
	int * data;
} histogram;

extern histogram * his_init(int width, int size);
extern void his_insert(histogram * his, int key);
extern double his_range_ratio(histogram * his, int left, int right);

#endif